package com.lagou.homework.stage2.no3;

/**
 * 第三题：
 * 手机卡类
 */
public class MobileCard {

//    private String cardType; // 卡片类型
    private MobileCardType cardType; // 手机卡类型
    private String cardNo; // 卡号
    private String userName; // 用户名
    private String password; // 密码
    private double accountBalance; // 账户余额
    private int talkTime; // 通话时长（分钟）
    private String netFlow; // 上网流量

    public MobileCard() {
    }

    public MobileCard(MobileCardType cardType, String cardNo, String userName, String password, double accountBalance, int talkTime, String netFlow) {
        this.cardType = cardType;
        this.cardNo = cardNo;
        this.userName = userName;
        this.password = password;
        this.accountBalance = accountBalance;
        this.talkTime = talkTime;
        this.netFlow = netFlow;
    }

    public MobileCardType getCardType() {
        return cardType;
    }
    public void setCardType(MobileCardType cardType) {
        this.cardType = cardType;
    }
    public String getCardNo() {
        return cardNo;
    }
    public void setCardNo(String cardNo) {
        this.cardNo = cardNo;
    }
    public String getUserName() {
        return userName;
    }
    public void setUserName(String userName) {
        this.userName = userName;
    }
    public String getPassword() {
        return password;
    }
    public void setPassword(String password) {
        this.password = password;
    }
    public double getAccountBalance() {
        return accountBalance;
    }
    public void setAccountBalance(double accountBalance) {
        this.accountBalance = accountBalance;
    }
    public int getTalkTime() {
        return talkTime;
    }
    public void setTalkTime(int talkTime) {
        this.talkTime = talkTime;
    }
    public String getNetFlow() {
        return netFlow;
    }
    public void setNetFlow(String netFlow) {
        this.netFlow = netFlow;
    }

    /**
     * 显示（卡号 + 用户名 + 当前余额）
     */
    public void show(){
        System.out.println("卡号："+getCardNo() + ", 用户名：" + getUserName() + ", 当前余额："+getAccountBalance());
    }
}
